home *** CD-ROM | disk | FTP | other *** search
/ Pascal Super Library / Pascal Super Library (CW International)(1997).bin / DELPHI32 / COMPNENT / DTOOLS3 / DEMOBWCC.PAS < prev    next >
Pascal/Delphi Source File  |  1995-11-01  |  1KB  |  67 lines

  1. unit Demobwcc;
  2.  
  3. interface
  4.  
  5. uses
  6.   SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls,
  7.   Forms, Dialogs, Toggler, StdCtrls, Custbtn;
  8.  
  9. type
  10.   TBWCCControls = class(TForm)
  11.     GroupBox1: TGroupBox;
  12.     rbBlack: TBWCCRadioButton;
  13.     rbNavy: TBWCCRadioButton;
  14.     chkGross: TBWCCCheckBox;
  15.     ShadowButton1: TShadowButton;
  16.     rbMaroon: TBWCCRadioButton;
  17.     rbGreen: TBWCCRadioButton;
  18.     procedure FormActivate(Sender: TObject);
  19.     procedure chkGrossClick(Sender: TObject);
  20.     procedure rbClick(Sender: TObject);
  21.   private
  22.     { Private declarations }
  23.   public
  24.     { Public declarations }
  25.   end;
  26.  
  27. var
  28.   BWCCControls: TBWCCControls;
  29.  
  30. implementation
  31.  
  32. {$R *.DFM}
  33. uses
  34.   DemoMain;
  35.  
  36. procedure TBWCCControls.FormActivate(Sender: TObject);
  37. begin
  38.   chkGross.Checked := not FrontPanel.BWCCBtn.Bitmap.Empty;
  39. end;
  40.  
  41. procedure TBWCCControls.chkGrossClick(Sender: TObject);
  42. begin
  43.   if chkGross.Checked then
  44.     FrontPanel.LoadGrossBitmaps
  45.   else
  46.     FrontPanel.UnloadGrossBitmaps;
  47. end;
  48.  
  49. procedure TBWCCControls.rbClick(Sender: TObject);
  50. var
  51.   col: TColor;
  52. begin
  53.   if Sender = rbBlack then
  54.     col := clBlack
  55.   else if Sender = rbNavy then
  56.     col := clNavy
  57.   else if Sender = rbMaroon then
  58.     col := clMaroon
  59.   else
  60.     col := clGreen;
  61.  
  62.   (Sender as TBWCCRadioButton).CheckColor := col;
  63.   chkGross.CheckColor := col;
  64. end;
  65.  
  66. end.
  67.